package com.gitee.linmt.entity;

import com.gitee.linmt.converter.DictionaryEnumConverter;
import com.gitee.linmt.enums.AccountState;
import com.gitee.linmt.enums.Gender;
import lombok.Data;

import javax.persistence.*;

/**
 * @author lin-mt
 * @version 1.0.0
 * @since 1.0.0
 */
@Data
@Entity(name = "user_info")
public class UserInfo {

    @Id
    private Long id;

    @Column(length = 4)
    @Convert(converter = DictionaryEnumConverter.class)
    private Gender gender;

    @Column(name = "account_state")
    @Convert(converter = DictionaryEnumConverter.class)
    private AccountState accountState;
}
